package ar.edu.utn.frsf.tpae.a2012.g03.impl;

import org.hibernate.Session;
import org.hibernate.SessionFactory;
import org.hibernate.cfg.AnnotationConfiguration;

public class Probador {

	
	private static SessionFactory sessionFactory = new AnnotationConfiguration().configure().buildSessionFactory();
	
	/**
	 * @param args
	 */
	public static void main(String[] args) {
		Session session = sessionFactory.openSession();
		session.getTransaction().begin();
		session.createQuery("DELETE * FROM cja_aho").executeUpdate();
		session.createQuery("DELETE * FROM cli").executeUpdate();
		session.createQuery("DELETE * FROM cta").executeUpdate();
		session.createQuery("DELETE * FROM cta_cte").executeUpdate();
		session.createQuery("DELETE * FROM mov").executeUpdate();
		session.createQuery("DELETE * FROM mov_pag").executeUpdate();
		
		session.getTransaction().commit();
	}

}
